<template>
	<view class="scene_recommend">
		<view class="travelItem flex flexVcen" v-for="(item, index) in list" :key="index" @click="navtoScenicDetails(item.scenicId, item.scenicName)">
			<image :src="item.scenicPicture1" mode="aspectFill" ></image>
			<view class="content">
				<view class="header">
					{{item.scenicName}}
				</view>
				<view class="instoduction  textHd2">
					{{item.scenicContent}}
				</view>
				<view class="tag">
					<view class="tagItem textHd">
						{{item.labelOne}}
					</view>
					<view class="tagItem textHd">
						{{item.labelTwo}}
					</view>
				</view>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		name: 'scene',
		props: {
		list: {
			  type: Array,
			  required: true,
			  default () {
				  return []
			  }
		  }	
		},
		methods:{
			// 跳转到景点详情页
			navtoScenicDetails (id, title) {
				uni.navigateTo({
					url: `../scenic_details/scenic_details?id=${id}&title=${title}`,
				})
			}
		}
	}
</script>

<style lang="scss" scoped>
	.scene_recommend {
	.travelItem {
		&:first-child {
			margin-top: 0;
			border-radius: 0 0 24rpx 24rpx;
		}
			margin-top: $margin_top;
			background-color: #fff;
			border-radius: 24rpx;
			border: 1rpx solid #fafafa;
			justify-content: space-around;
			image {
				width: 180rpx;
				height: 180rpx;
				border-radius: 12rpx;
			}
			.content {
				padding: 12rpx 0;
				width: 510rpx;
				.header {
					font-size: 32rpx;
					font-weight: bolder;
				}
				.tag {
					padding-top: 16rpx;
					.tagItem {
						padding: 4rpx 6rpx;
						max-width: 180rpx;
						display: inline-block;
						border: 1rpx solid #faad14;
						color: #faad14;
						border-radius: 6rpx;
						font-size: 24rpx;
						margin-right: 24rpx;
					}
				}
				.instoduction {
					padding-top: 16rpx;
					color: #999;
				}
			}
		}
		}
</style>
